﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Revis.VClinicNet.App.Internal.Dto.Mappers
{
    public interface IDtoMapper
    {
        void Map();
    }

    public interface IDtoMapperInitializer
    {
        void Initialize();
    }

    public class DtoMapperInitializer : IDtoMapperInitializer
    {
        private IEnumerable<IDtoMapper> _mappers;

        public DtoMapperInitializer(IEnumerable<IDtoMapper> mappers)
        {
            _mappers = mappers;
        }

        public void Initialize()
        {
            foreach (IDtoMapper dtoMapper in _mappers) {
                dtoMapper.Map();
            }
        }
    }
}
